package com.highgain.displacementtrend.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.highgain.displacementtrend.entity.Device;
import com.highgain.displacementtrend.entity.DeviceData;
import org.apache.ibatis.annotations.Param;
import java.util.List;

/**
 * @author zhanglifeng
 * @date 2021/04/13 19:35
 **/
public interface DeviceDataMapper extends BaseMapper<DeviceData> {

    /**
     * 保存数据
     * @param deviceData 形变量
     * @return 是否成功
     */
    int insertData(DeviceData deviceData);

    IPage<DeviceData> queryDeviceData(Page<DeviceData> page, @Param("d") Device device);

    List<DeviceData> queryAll(@Param("d") Device device);
}
